package ooday01.homework2;
//- Car类：brand(品牌)，color，price，构造方法()，start()、run()、stop()
public class Car {
    String brand; //品牌
    String color; //颜色
    double price; //价格

    Car() {
    }

    Car(String brand, String color, double price) {
        this.brand = brand;
        this.color = color;
        this.price = price;
    }
    void start2 () {
        System.out.println(brand + "牌子的" + color + "颜色的" + price + "块钱的车动了");
    }
    void run2 () {
        System.out.println(brand + "牌子的" + color + "颜色的" + price + "块钱的车废了");
    }
    void stop2 () {
        System.out.println(brand + "牌子的" + color + "颜色的" + price + "块钱的车停止了");
    }


}

